package com.example.demo.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.math.BigDecimal;
import java.time.LocalDateTime;

@Data
@TableName("products")
public class Product {
    
    @TableId(value = "product_id", type = IdType.AUTO)
    private Integer productId;
    
    @TableField("name")
    private String name;
    
    @TableField("description")
    private String description;
    
    @TableField("price")
    private BigDecimal price;
    
    @TableField("stock")
    private Integer stock;
    
    @TableField("category_id")
    private Integer categoryId;
    
    @TableField("merchant_id")
    private Integer merchantId;
    
    @TableField("is_pet")
    private Boolean isPet;
    
    @TableField("is_available")
    private Boolean isAvailable;
//
//    @TableField("image_url")
//    private String imageUrl;
    
    @TableField("created_at")
    private LocalDateTime createdAt;
    
    @TableField("updated_at")
    private LocalDateTime updatedAt;
    
    @TableField(exist = false)
    private Category category;
    
    @TableField(exist = false)
    private User merchant;
} 